4 # Helps generate autoconf/automake stuff, when code is checked
7 # The script is copied from util-linux package.
11 test -z "$srcdir" && srcdir=.
17 test -f src/dhcpd-pools.c || {
19 echo "You must run this script in the top-level dhcpd-pools directory"
24 (autoconf --version) < /dev/null > /dev/null 2>&1 || {
26 echo "You must have autoconf installed to generate dhcpd-pools build system."
30 (autoheader --version) < /dev/null > /dev/null 2>&1 || {
32 echo "You must have autoheader installed to generate dhcpd-pools build system."
33 echo "The autoheader command is part of the GNU autoconf package."
37 (libtool --version) < /dev/null > /dev/null 2>&1 || {
39 echo "You must have libtool-2 installed to generate dhcpd-pools build system."
43 (automake --version) < /dev/null > /dev/null 2>&1 || {
45 echo "You must have automake installed to generate dhcpd-pools build system."
50 ltver=$(libtoolize --version | awk '/^libtoolize/ { print $4 }')
51 test ${ltver##2.} = "$ltver" && {
52 echo "You must have libtool version >= 2.x.x, but you have $ltver."
56 if test "$DIE" -eq 1; then
61 echo "Generate build-system by:"
62 echo " aclocal: $(aclocal --version | head -1)"
63 echo " autoconf: $(autoconf --version | head -1)"
64 echo " autoheader: $(autoheader --version | head -1)"
65 echo " automake: $(automake --version | head -1)"
66 echo " libtoolize: $(libtoolize --version | head -1)"
69 libtoolize --force $LT_OPTS
73 automake --add-missing $AM_OPTS
78 echo "Now type '$srcdir/configure' and 'make' to compile."